	    function chooseType(a, type) {
	    	eval("$('li#" + type + "').siblings().removeClass('highlight')");
	    	eval("$('li#" + type + "').addClass('highlight')");

	    	var $content = $('#content');
	    	var html = '';
	    	html += '<h2 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">waiting。。。<h2>'
	    			+ '<img src="./images/contentloading.gif" alt="loading.."/>';
	    	$content.html(html);
	    	var link = a.href;
	    	//alert(link);
//	    	typeLoad(link, $content, type);
	    	//alert("asd");
	    	return false;
	    }
	    function logDisplay(a) {
	    	var $content = $('#content');
	    	var html = '';
	    	html += '<h2 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">waiting...<h2>'
	    		+ '<img src="./images/contentloading.gif" alt="loading.."/>';
	    	$content.html(html);
	    	var link = a.href;
	    	logLoad(link, $content);
	    	return false;
	    }
	    function logDetail(a, id) {
	    	var $content = $('#content');
	    	var html = '';
	    	html += '<h2 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">waiting...<h2>'
	    		+ '<img src="./images/contentloading.gif" alt="loading.."/>';
	    	$content.html(html);
	    	var link = a.href;
	    	typeLoad(link, $content, id);
	    	return false;
	    }
	    function logCtrl(a, batchLogId, detailID, handleMode) {
	    	var $content = $('#content');
	    	var html = '';
	    	html += '<h2 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">waiting...<h2>'
	    		+ '<img src="./images/contentloading.gif" alt="loading.."/>';
	    	$content.html(html);
	    	var link = a.href;
	    	ctrl(link, $content, batchLogId, detailID, handleMode);
	    	return false;
	    }
	    function topage( url, pageNo, logId, content) {
//	    	alert("asd");
//	    	alert(url);
//	    	alert(url + "/exception/shown!detailShown.do");
	    	var $content = eval("$('#" + content +"')");
	    	$.ajax({
	    		type : "post",
	    		url :  url,
	    		data : {
	    			'pageNo' : pageNo,
	    			'logId' :  logId
	    		},
	    		timeout : 20000,
	    		success : function(data) {
	    			$content.html(data);
	    		},
	    		error : function() {
	    			content.html('<h1 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">Errors!!</h1>');
	    		}
	        });
	    	
	    	return false;
	    }
	    
function runDelog(a, logID, detailID, handleMode, content) {
	var link = a.href;
	var $content = eval("$('#" + content +"')");
	var html = '';
	html += '<h2 class="u-title"><font color="#FF4500" >RERUNNING!!!</font></h2>';
	$content.html(html);
	$.ajax({
		type : "post",
		url : link,
		data : {
			'logID' : logID,
			'detailID' : detailID,
			'handleMode' : handleMode
		},
		success : function(data) {
			$content.html(data);
		},
		error : function() {
			content.html('<h2 class="u-title"><font color="#FF4500" >ERROR!!!</font></h2>');
		}
    });
	
	return false;
}
function run(a, divId, content) {
	var $closeDiv = eval("$('#" + divId +"')");
	$closeDiv.window('close');
	var link = a.href;
	var $content = eval("$('#" + content +"')");
	var html = '';
	html += '<h2 class="u-title"><font color="#FF4500" >RUNNING!!!</font></h2>';
	$content.html(html);
	$.ajax({
		type : "post",
		url : link,
		data : {
			'batchNo' : $("#run_batchNo").val(),
			'jobNo' : $("#run_jobNo").val(),
			'stepNo' : $("#run_stepNo").val(),
			'batchTime' : $("#run_batchTime").val()
		},
		success : function(data) {
			$content.html(data);
			
			$("#run_batchNo").val("");
			$("#run_jobNo").val("");
			$("#run_batchTime").val("");
			$("#run_stepNo").val("");
		},
		error : function() {
			content.html('<h1 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">Errors!!</h1>');
		}
	});
	
	return false;
}
function runStep(a, divId, content) {
	var $closeDiv = eval("$('#" + divId +"')");
	$closeDiv.window('close');
	var link = a.href;
	var $content = eval("$('#" + content +"')");
	var html = '';
	html += '<h2 class="u-title"><font color="#FF4500" >RUNNING!!!</font></h2>';
	$content.html(html);
	$.ajax({
		type : "post",
		url : link,
		data : {
			'batchNo' : $("#run_batchNo").val(),
			'jobNo' : $("#run_jobNo").val(),
			'stepNo' : $("#run_stepNo").val(),
			'batchTime' : $("#run_batchTimeS").val()
		},
		success : function(data) {
			$content.html(data);
			
			$("#run_batchNo").val("");
			$("#run_jobNo").val("");
			$("#run_batchTimeS").val("");
			$("#run_stepNo").val("");
		},
		error : function() {
			content.html('<h1 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">Errors!!</h1>');
		}
	});
	
	return false;
}

function addTime(divId,batchNo,jobNo,stepNo){
	
	var $showDiv = eval("$('#" + divId +"')");
	
	$('#run').removeClass("blue5");
	$(this).addClass("blue5");
	
	$("#run_batchNo").val(batchNo);
	$("#run_jobNo").val(jobNo);
	
	if(stepNo == null){
		$("#run_stepNo").val("");
	}else{
		$("#run_stepNo").val(stepNo);
	}
	
	$("#run_batchTime").val("");
	
	$showDiv.window('open');
}
function ctrl(link, content , batchLogId, detailID, handleMode) {
	$.ajax({
		type : "post",
		url : link,
		data : {
			'logID' : batchLogId,
			'detailID' : detailID,
			'handleMode' : handleMode
		},
		success : function(data) {
			content.html(data);
		},
		error : function() {
			content
			.html('<h1 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">发生错误</h1>');
		}
	});
}
function typeLoad(link, content , id) {
	$.ajax({
		type : "post",
		url : link,
		data : {
			'logId' : id
		},
		success : function(data) {
			content.html(data);
		},
		error : function() {
			content
			.html('<h1 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">发生错误</h1>');
		}
	});
}
function logLoad(link, content) {
	$.ajax({
		type : "post",
		url : link,
		data : {
		},
		success : function(data) {
			content.html(data);
		},
		error : function() {
			content
			.html('<h1 style=" margin:2px; width:80%; color:#336699; font-size:14px; line-height:16px; text-align:left; font-weight:lighter; padding-left:5px;">发生错误</h1>');
		}
	});
}















